from decimal import Decimal
from enum import Enum
from pydantic import BaseModel


class IDModelMixin(BaseModel):
    id: int


class Status(str, Enum):
    pending = "pending"
    paid = "paid"
    shipped = "shipped"
    completed = "completed"
    cancelled = "cancelled"


class Method(str, Enum):
    wechat = "wechat"
    alipay = "alipay"


class OrderItems(BaseModel):
    id: int
    scope_quantity: Decimal


class Create(BaseModel):
    is_menu: int
    order_item: OrderItems
    id: int
    address_id: int
    remark: str


class Payment(BaseModel):
    order_id: str


class UpdateStatus(BaseModel):
    status: Status
